using UnityEngine;
using System.Collections;
namespace Azuo_Tool
{
    public class Single_Behaviour<T> : MonoBehaviour where T : Single_Behaviour<T>
    {
        protected static T S_object;

        public static T Get_obj
        {
            get
            {
                return S_object;
            }
        }

        protected virtual void Awake()
        {
            // Debug.Log("11111");
            if (S_object == null)
            {
                S_object = this as T;
            }
            else
            {
                GameObject.Destroy(this.gameObject);
            }
        }
    }
}
